<form class="layui-form layui-box" style='padding:25px 30px 20px 0' action="__SELF__" data-auto="true" method="post">
    <div class="layui-form-item">
        <label class="layui-form-label">标签名称</label>
        <div class="layui-input-block">
            {if $label and isset($label.title)}
            <input name="title" value='{$label.title|default=""}'
                   required="required" title="标签名称必填" placeholder="请输入标签名称" class="layui-input ">
            {else /}
            <input name="title" value='{$label.title|default=""}' required="required"
                   title="标签名称必填" class="layui-input">
            {/if}
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label">标签标志</label>
        <div class="layui-input-block">
            {if $label and isset($label.sign)}
            <input name="sign" value='{$label.sign|default=""}'
                   required="required" title="标签标志必填" placeholder="请输入标签标志" class="layui-input ">
            {else /}
            <input name="sign" value='{$label.sign|default=""}' required="required"
                   title="标签名称必填" class="layui-input">
            {/if}
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label">是否开启</label>
        <div class="layui-input-block">
            <input type="radio"  name="status" value="1"  {if condition="$label.status nheq 0"} checked {/if} title="是" >
            <input type="radio"  name="status" value="0" {if condition="$label.status heq 0"} checked {/if}  title="否" >
        </div>
    </div>
    <div class="hr-line-dashed"></div>
    <div class="layui-form-item text-center">
        {if isset($label['id'])}<input type='hidden' value='{$label.id}' name='id'/>{/if}
        <button class="layui-btn" type='submit'>保存数据</button>
        <button class="layui-btn layui-btn-danger" type='button' data-confirm="确定要取消编辑吗？" data-close>取消编辑</button>
    </div>
    <script>window.form.render();</script>
</form>
